package cn.edu.zafu.bigdata.liuwenyi;

class Animal {
    public void makeSound(){
        System.out.println("Animal sound");
    }
}

class Dog extends Animal{
    @Override
    public void makeSound() {
        System.out.println("Woof!");
    }
}

class Cat extends Animal{
    @Override
    public void makeSound() {
        System.out.println(("Meow!"));
    }
}


public class Animal_Test{
    public static void main(String[] args) {
        Dog dog = new Dog();
        dog.makeSound();

        Cat cat = new Cat();
        cat.makeSound();
    }

}

